
import 'base_res.dart';

class CreditRecordModel extends BaseItem {
  CreditRecordModel({
    this.content,
    this.cover,
    this.href,
    this.id,
    this.title,
    this.type,
    this.integral,
    this.createdAt,
  });

  CreditRecordModel.fromJson(dynamic json) {
    content = json['content'];
    cover = json['cover'];
    href = json['href'];
    id = json['id'];
    title = json['title'];
    type = json['type'];
    integral = json['integral'];
    createdAt = json['createdAt'];
    name = json['name'];
    desc = json['desc'];
    price = (json['price'] ?? 0).toString();
  }

  String? content;
  String? cover;
  String? href;
  String? id;
  String? title;
  num? type;
  String? price;
  num? integral;
  String? createdAt;
  String? name;
  String? desc;

  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['content'] = content;
    map['cover'] = cover;
    map['href'] = href;
    map['id'] = id;
    map['title'] = title;
    map['integral'] = integral;
    map['type'] = type;

    return map;
  }

  @override
  fromJson(json) {
    CreditRecordModel.fromJson(json);
  }
}
